package com.example.demo.enums;
import lombok.Getter;

/**
 * @description：响应状态码枚举.
 * @author：lw
 * @since：2023/12/28
 **/

@Getter
public enum StatusCodeEnum {
    success(200,"操作成功"),
    add_success(200,"新增成功"),
    delete_success(200,"删除成功"),
    query_success(200,"查询成功"),
    update_success(200,"更新成功"),
    export_success(200,"导出成功"),
    import_success(200,"导入成功"),
    ban_success(200,"禁用成功"),
    unban_success(200,"解除禁用成功"),
    bind_success(200,"绑定成功"),
    unbind_success(200,"解绑成功"),
    upShelf_success(200,"上架成功"),
    downShelf_success(200,"下架成功"),
    giveAuth_success(200,"授权成功"),
    give_success(200,"分配成功"),
    upload_success(200,"文件上传成功"),
    upload_size_over(201,"上传文件大小超过限制"),
    download_success(200,"文件下载成功"),
    giveRoles_success(200,"角色分配成功"),
    login_success(200,"登录成功"),
    logout_success(200,"退出登录成功"),
    username_null(201,"用户名为空！"),
    password_null(201,"密码为空！"),
    user_baned(201,"当前用户被禁用！"),
    codeKey_null(201,"图像验证码key为空！"),
    codeValue_null(201,"图形验证码值为空！"),
    codeValue_error(201,"图形验证码值错误！"),
    codeValue_no_exist(201,"图形验证码失效或未获取！"),
    phone_error(201,"手机号格式错误！"),
    phone_no_exist(201,"该手机号未注册！"),
    shortMessageCaptcha_send_fail(201,"短信验证码发送失败！"),
    shortMessageCaptcha_hasSend(201,"短信验证码已发送过了，请勿频繁操作！"),
    shortMessageCaptcha_null(201,"短信验证码为空！"),
    shortMessageCaptcha_error(201,"短信验证码错误！"),
    shortMessageCaptcha_no_exist(201,"短信验证码失效或未获取！"),
    shortMessageCaptcha_(201,"短信验证码错误！"),
    wxBindKeyOutDate(201,"微信授权失效，请重新授权绑定！"),
    username_error(201,"用户名错误！"),
    password_error(201,"密码错误！"),
    upload_fail(201,"文件上传失败！"),
    download_fail(201,"文件下载失败！"),
    give_fail(201,"分配失败！"),
    token_null(401,"请携带登录凭证！"),
    token_invalid(401,"无效的登录凭据！"),
    server_error(500,"服务器异常，请联系管理员！"),
    import_error(201,"数据格式不正确，请参考表格现有的数据格式编写excel"),
    add_fail(201,"新增失败！"),
    update_fail(201,"更新失败！"),
    delete_fail(201,"删除失败！"),
    query_fail(201,"查询失败！"),
    fileName_err(201,"文件名错误！"),
    fileName_null(201,"文件名为空！"),
    file_null(201,"文件为空！"),
    noAuth(401,"您无权访问该资源！")

    ;




    private final Integer code;
    private final String message;

    StatusCodeEnum(Integer code,String message){
      this.code=code;
      this.message=message;
    }
}
